package cn.com.infcn.monitor.web;

import java.io.IOException;
import java.io.OutputStream;

import javax.servlet.ServletOutputStream;
import javax.servlet.WriteListener;

class FilterServletOutputStream extends ServletOutputStream {
	private final OutputStream stream;

	FilterServletOutputStream(OutputStream output) {
		super();
		assert output != null;
		stream = output;
	}

	@Override
	public void close() throws IOException {
		stream.close();
	}

	@Override
	public void flush() throws IOException {
		stream.flush();
	}

	@Override
	public void write(int b) throws IOException {
		stream.write(b);
	}

	@Override
	public void write(byte[] bytes) throws IOException {
		stream.write(bytes);
	}

	@Override
	public void write(byte[] bytes, int off, int len) throws IOException {
		stream.write(bytes, off, len);
	}

	public boolean isReady() {
		return false;
	}

	public void setWriteListener(WriteListener writeListener) {
		
	}
}
